package com.xc.h05.mapper;

import com.xc.h05.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author 30658
* @description 针对表【user】的数据库操作Mapper
* @createDate 2025-03-07 19:54:45
* @Entity com.xc.h05.entity.User
*/
@Mapper
public interface UserMapper {
    User findByUsername(@Param("userName") String username, @Param("password") String password);

    int deleteByPrimaryKey(Long id);

    int insert(User record);

    int insertSelective(User record);

    User selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(User record);

    int updateByPrimaryKey(User record);
    List<User> findAll();
    // 根据id查询 没有写controller的对应方法
    User findById(Long id);
    //根据多个id查询
    List<User> findByIds(List list);
}
